<div ng-class="{
    'form-horizontal': properties.labelPosition === 'left' && !properties.labelHidden,
    'row': properties.labelPosition === 'top' && !properties.labelHidden || properties.labelHidden
    }">
    <div class="form-group">
        <label
            ng-if="!properties.labelHidden"
            ng-class="{ 'control-label--required': properties.required }"
            class="control-label col-xs-{{ !properties.labelHidden && properties.labelPosition === 'left' ? properties.labelWidth : 12 }}"
            ng-bind-html="properties.label | uiTranslate">
        </label>
        <div class="col-xs-{{ 12 - (!properties.labelHidden && properties.labelPosition === 'left' ? properties.labelWidth : 0) }}">
            <label ng-if="properties.inline" class="radio-inline" ng-repeat="option in properties.availableValues track by $index">
                <input
                    type="radio"
                    name="{{ctrl.name}}"
                    ng-model="properties.selectedValue"
                    ng-value="ctrl.getValue(option)"
                    ng-required="properties.required"
                    ng-disabled="properties.disabled">
                {{ (ctrl.getLabel(option) || option) | uiTranslate }}
            </label>

            <div ng-if="!properties.inline" class="radio radio-button-margin" ng-repeat="option in properties.availableValues track by $index">
                <label>
                    <input
                        type="radio"
                        name="{{ctrl.name}}"
                        ng-model="properties.selectedValue"
                        ng-value="ctrl.getValue(option)"
                        ng-required="properties.required"
                        ng-disabled="properties.disabled">
                    {{ (ctrl.getLabel(option) || option) | uiTranslate }}
                </label>
            </div>
        </div>
        <div ng-messages="$form[ctrl.name].$dirty && $form[ctrl.name].$error " ng-messages-include="forms-generic-errors.html" role="alert"></div>
    </div>
</div>
